import styled from 'styled-components'
import logoPic from '../../statics/logo.png'

export const HeaderWrapper = styled.div`
position: relative;
height: 56px;
border-bottom: 1px solid #f0f0f0;
`

export const Logo = styled.div`
position: absolute;
top: 0;
left: 0;
width: 100px;
height: 56px;
margin-left: 260px;
display: inline-block;
background: url(${logoPic});
background-size: contain;
`

export const Nav = styled.div`
width: 1160px;
height: 100%;
padding-right: 70px;
box-sizing: border-box;
margin: 0 auto;
`

export const NavItem = styled.div`
line-height: 56px;
padding: 0 15px;
font-size: 17px;
color: #333;
&.left{
    float: left;
}
&.right{
    float: right;
    color: #969696;
    .a{
        font-size: 24px;
    }
}
&.active{
    color: #ea6f5a;
}
`

export const SearchWrapper = styled.div`
position: relative;
float: left;
.zoom{
    position: absolute;
    right: 5px;
    bottom: 4px;
    width: 30px;
    line-height: 30px;
    border-radius: 15px;
    text-align: center;
    font-size: 24px;
    color: #969696;
    &.focused{
        background: #888;
        color: #fff;
    }
}
`

export const NavSearch = styled.input.attrs({
    placeholder: '索搜'
})`
width: 220px;
height: 38px;
padding: 0 32px 0 20px;
margin-top: 9px;
margin-left: 20px
box-sizing: border-box;
border: none;
outline: none;
border-radius: 19px;
background: #eee;
&::placeholder{
    color: #888;
}
&.focused{
    width: 280px;
}
&.slide-enter{
    transition: all .4s ease-out;
}
&.slide-enter-active{
    width: 280px;
}
&.slide-exit{
    transition: all .4s ease-out;
}
&.slide-exit-active{
    width: 220px;
}`

export const SearchInfo = styled.div`
position: absolute;
z-index: - 100;
left: 20px;
top: 56px;
width: 220px;
padding: 0 24px;
box-shadow: 0 0 8px rgba(0,0,0,.2);
background: #fff;
`
export const SearchInfoTitle = styled.div`
margin: 20px 0 15px 0;
line-height: 20px;
font-size: 14px;
color: #969696;
`

export const SearchInfoSwitch = styled.span`
float: right;
font-size: 13px;
.spin{
    display: block;
    float: left;
    font-size: 12px;
    margin-right: 2px;
    transition: all .2s ease-in;
    transform: rotate(0deg);
    transform-origin: center center;
`

export const SearchInfoList = styled.div`

`

export const SearchInfoItem = styled.a`
display: block;
float: left;
line-height: 20px;
padding: 0 5px;
margin: 0 10px 15px 0;
font-size: 13px;
border: 1px solid #ddd;
border-radius: 3px;
color: #787878;
`

export const Addition = styled.div`
position: absolute;
right:0;
top: 0;
height: 56px;
margin-right: 210px;
`

export const Button = styled.button`
float: right;
margin-top: 9px;
margin-right: 20px;
padding:0 20px;
line-height: 38px;
border: 1px solid #ec6149;
border-radius: 19px;
outline: none;
cursor: pointer;
&.reg{
    color: #ec6149;
    background: #fff;
}
&.writing{
    color: #fff;
    background: #ec6149;
    .ic-write{
        margin-right: 6px;
    }
}
`